#include <bits/stdc++.h>
using namespace std;

const int N = 1e5 + 5;
int fi[N];
bool used[N];

int main()
{
    freopen("duel.in", "r", stdin);
    freopen("duel.out", "w", stdout);

    int n;
    cin >> n;
    int cnt = n;
    for(int i = 1; i <= n; i++)
    {
        cin >> fi[i];
    }
    for(int i = 1; i <= n; i++)
    {
        for(int j = 1; j <= n; j++)
        {
            if(fi[i] > fi[j] && used[i] == 0)
            {
                used[i] = 1;
                cnt--;
            }
            else if(fi[j] > fi[i] && used[j] == 0)
            {
                used[j] = 1;
                cnt--;
            }
        }
    }
    cout << cnt;
    return 0;
}
